﻿//////////////////////////////////////////////////////////////////////////////
//
//  Copyright © 1998-2024 Glodon Company Limited.  All rights reserved.
//
//  Use of this software is subject to the terms of the Glodon license
//  agreement provided at the time of installation or download, or which
//  otherwise accompanies this software in either electronic or hard copy form.  
//
//////////////////////////////////////////////////////////////////////////////


#pragma once
#include "GcmpGeometryInterface.h"

namespace gcmp
{
    /*!
    *@struct MeshSimplifyOptions
    *@brief  Mesh简化过程中的参数
    */
    struct MeshSimplifyOptions
    {
        double CompressionRatio;                ///<简化比例
        double GeoDisThreshold;                 ///<简化后的网格到原始网格的几何距离阈值，超过阈值将退出简化
        bool WeldOnlyObjectBound;               ///<是否只聚合object的边界
        bool IsRemoveOverlapTris;               ///<是否移除重叠面片

        MeshSimplifyOptions(double compressionRatio, double geoDisThreshold, bool weldOnlyObjectBound = false, bool isRemoveOverlapTris = false)
            :CompressionRatio(compressionRatio)
            , GeoDisThreshold(geoDisThreshold)
            , WeldOnlyObjectBound(weldOnlyObjectBound)
            , IsRemoveOverlapTris(isRemoveOverlapTris)
        {}
    };
}
